package com.sxdz.controller.service.goods

import com.sxdz.controller.service.IBaseService
import com.sxdz.models.TGoodsInfo
import com.sxdz.models.common.Order
import com.sxdz.models.common.RollPage
import org.apache.ibatis.annotations.Param

/**
 * Created by LiYan on 2016/8/4.
 */
interface IGoodsService extends IBaseService{
    /**
     * 查询商品信息列表
     * @param params
     * @return
     */
    List<TGoodsInfo> findListByParams(Map<String, Object> params)

    /***
     *根据商品信息查询 商品详情
     */
    TGoodsInfo  selectByPrimaryKey(Long id);

    /**
     * 按参数查询单个商品
     * @param params
     * @return
     */
    TGoodsInfo findObj(Map<String, Object> params)

    /**
     * 按商品类型查询goodsInfo和goodsBanner
     * @param module
     * @return
     */
    /*List<Map<String,Object>> findListByModule()*/
    RollPage findListByModule(Map<String, Object> params, Order order, Integer pageNum, Integer pageSize)throws Exception;

    Integer findCountByModule(@Param(value = "params") Map<String, Object> params);

}
